local Locales = {
	["Darkwitch Gurka"] = {
		[1] = "Darkwitch Gurka",
		[2] = "Dämmerhexe Gurka",
		[3] = "Sorcîère ténébreuse Gurka",
	},
	["Deadly Defilement"] = { --35934
		[1] = "Deadly Defilement",
		[2] = "Tödliche Besudelung",
		[3] = "Profanation mortelle",
	},
	["Blinding Dark"] = { --44315
		[1] = "Blinding Dark",
		[2] = "Blendende Dunkelheit",
		[3] = "Obscurité aveuglante",
	},
}

local function RKVGurka(tUnits)
	local currTime = GameLib.GetGameTime()
	for unitid, unitdata in pairs(tUnits) do
		local unitname = unitdata.unit:GetName()
		if unitname == Raiderino.L["Darkwitch Gurka"] then
			local castname = Raiderino:GetCast(unitid,unitdata.unit)
			if castname then
				if castname == Raiderino.L["Deadly Defilement"] then
					if Raiderino:FeatureCheck("Darkwitch Gurka","Deadly Defilement") then
						local msg = {text = "Deadly Defilement", maxtime = 10, icon = nil, destroyAtEnd = false}
						Raiderino.timers:AddTimer(msg)
					end
				elseif castname == Raiderino.L["Blinding Dark"] then
					if Raiderino:FeatureCheck("Darkwitch Gurka","Blinding Dark") then
						local msg = {text = "Interrupt this cast!", maxtime = 4, icon = nil, destroyAtEnd = false}
						Raiderino.notifications:AddTimer(msg)
					end
				else
					Raiderino:UntimedCastAdd(unitname,castname)
				end
			end
		end
	end
end

local function PhaseGurka(phase)

end

local function StartGurka()

end

local encounteroptions = {
	enabled = true,
	position = 2,
	zone = "Ruins of Kel Voreth",
	fBossFunction = RKVGurka,
	fPhaseFunction = PhaseGurka,
	fOnStartCombat = StartGurka,
	features = {
		["Deadly Defilement"] = {
			displayname = "Deadly Defilement",
			enabled = true
		},
		["Blinding Dark"] = {
			displayname = "Blinding Dark",
			enabled = true
		},
	},
}

if _G["RaiderinoLibs"] == nil then
	_G["RaiderinoLibs"] = { }
end
if _G["RaiderinoLibs"]["Encounters"] == nil then
	_G["RaiderinoLibs"]["Encounters"] = { }
end

_G["RaiderinoLibs"]["Encounters"]["Darkwitch Gurka"] = encounteroptions

if _G["RaiderinoLibs"]["Locales"] == nil then
	_G["RaiderinoLibs"]["Locales"] = { }
end
for locale, localedata in pairs(Locales) do
	if not RaiderinoLibs.Locales[locale] then
		RaiderinoLibs.Locales[locale] = {}
		for i,localestring in pairs(localedata) do
			RaiderinoLibs.Locales[locale][i] = localestring
		end
	end
end